package cn.smartaccount.demo.common.util;

import cn.hutool.core.date.ChineseDate;
import cn.hutool.core.date.DateTime;
import cn.hutool.core.date.DateUtil;

/**
 * @author xuluquan
 * @date 2023-02-14 18:22
 */
public class LunarUtil {


    public static void main(String[] args) {

        DateTime date = DateUtil.date();
        ChineseDate chineseDate = new ChineseDate(date);
        String lunar = chineseDate.toString();
        String[] s = lunar.split(" ");

        System.out.println(s[0].substring(0,2) + "-- "+ s[1]);

    }



}





